import httpRequest from '@/utils/request'

// 查询学校列表
export function listSchool(query) {
	return httpRequest.request({
		url: '/market/school/list',
		method: 'post',
		data: query
	})
}

// 查询学校详细
export function getSchool(id) {
	return httpRequest.request({
		url: '/market/school/' + id,
		method: 'get'
	})
}

// 新增学校
export function addSchool(data) {
	return httpRequest.request({
		url: '/market/school',
		method: 'post',
		data: data
	})
}

// 修改学校
export function updateSchool(data) {
	return httpRequest.request({
		url: '/market/school',
		method: 'put',
		data: data
	})
}

// 删除学校
export function delSchool(id) {
	return httpRequest.request({
		url: '/market/school/' + id,
		method: 'delete'
	})
}